package com.five.api;

import com.five.dto.IdRequest;
import com.five.pojo.Novel;
import com.five.result.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;

@FeignClient(name = "novel-service")
public interface NovelApi {

    /**
     * 根据作者id获取作者所有书籍
     */
    @PostMapping("/novel/author/books")
    Result<List<Novel>> getAuthorBooks(@RequestBody IdRequest request);


}
